//用户相关的api接口
import request from '@/utils/requiest'
//1、验证手机号是否被注册
export const checkPhoneApi = (tel: string) => request.post('/user/docheckphone', { tel })

//2、发送短信验证码接口
export const sendCodeApi = (tel: string) => request.post('/user/dosendmsgcode', { tel })

// 3、验证短信验证码
export const checkCodeApi = (tel: string, telcode: string) => request.post('/user/docheckcode', { tel, telcode })

//4、验证俩次密码是否一致
export const registerApi = (tel: string, password: string) => request.post('/user/dofinishregister', { tel, password })

//5、登录方式接口
export const loginApi = (loginname: string, password: string) => request.post('/user/login', { loginname, password })

//6、获取用户详细信息Api
export const getUserInfoApi = (userid: string) => request.get('/user/info', { params: { userid } })